How to perge softDeleted object ?

Hi, I have softDeleted object and in my script I do:

if (isDeleted(o2BDeleted)) {
        error "The object is already deleted."
 }

So I can not make hard delete on softDeleted object. If I comment the code

if (null o2BDeleted){
        error "No Object for deletion is found."
     }

//if (isDeleted(o2BDeleted)) {
  //      error "The object is already deleted."
 //}

hardDelete(o2BDeleted) 

 

where o2BDeleted is the object which is softDeleted and is not null an error appears:

 <Line:32> cannot delete Object: no access to source object

How to make the purge on object not on Module? Is there way to understand if the object is soft deleted and to purge it?

 


Dinio - Mon Jan 04 04:07:12 EST 2016

Re: How to perge softDeleted object ?
Mike.Scharnow - Mon Jan 04 07:39:23 EST 2016

Well.

If you look for purging objects in the DXL manual, you only find the statement "string purgeObjects_(Module mod)" which purges all objects.

So, according to the DXL manual, I think you would have to a) undelete the object and b) hardDelete it.

However, if you look into the perms lists, you also find an unofficial statement "string purgeObject_ (Object)", which probably might do what you expect it to do (surprise: it does...)

You can see that this statement is there at least since DOORS version 5.2, so it seems not to be experimental and thus should be quite save to use. Up to you.

if (isDeleted(o2BDeleted)) {
    purgeObject_ (o2BDeleted)
}